/*****************************************Copyright(C)******************************************
******************************************* *********************************************
*------------------------------------------文件信息---------------------------------------------
* FileName          : top_scheme.h
* Author            : 张婷�?
* Version           : 1.0V
* Description       : 所有的协议配置方案
*----------------------------------------历史版本信息-------------------------------------------
* History           :
* Description       :
*-----------------------------------------------------------------------------------------------
***********************************************************************************************/
#ifndef TOP_SCHEME_H_
#define TOP_SCHEME_H_
/* Includes-----------------------------------------------------------------------------------*/

/* Private define-----------------------------------------------------------------------------*/
#define RS232_232_1 	0
#define RS485_DB9 		0
#define MODBUS_232_1 	0
#define MODBUS_CAN 		0
#define MODBUS_485 		0
//#define MODBUS_NB_IOT 	0
//#define MODBUS_4G_CAT1 	0
#define LEN_CONTROL_CAN 1
//#define MQTT_NB_IOT  	1
#define G4_CAT1 	1
#define LORA 		1
#define NB_IOT 		1
#define Temp_wet_RS485 		1

//#if MQTT_NB_IOT | MODBUS_NB_IOT
//	#define NB_IOT 1
//#else
//	#define NB_IOT 0
//#endif /*MQTT_NB_IOT*/


//#if MQTT_4G_CAT1 | MODBUS_4G_CAT1
//	#define G4_CAT1 1                                                                //数字不能做变量首字改为G4
//#else
//	#define G4_CAT1 0
//#endif /*MQTT_4G_CAT1*/


//#if MQTT_LORA
//	#define LORA 1
//#else
//	#define LORA 0
//#endif /*MQTT_LORA*/

#if RS232_232_1|MODBUS_232_1
	#define RS232_1 1
#else
	#define RS232_1 0
#endif /*RS232_232_1|MODBUS_232_1*/

#if RS485_DB9|MODBUS_485|Temp_wet_RS485
	#define RS485 1
#else
	#define RS485 0
#endif /*RS485_DB9|MODBUS_485*/

#if MODBUS_CAN|LEN_CONTROL_CAN
	#define CAN 1
#else
	#define CAN 0
#endif /*MODBUS_CAN|LEN_CONTROL_CAN*/

#if MODBUS_232_1|MODBUS_485|MODBUS_CAN
	#define MODBUS 1
#else
	#define MODBUS 0
#endif /*MODBUS_232_1|MODBUS_485|MODBUS_CAN*/

//#if MODBUS_4G_CAT1 | MODBUS_NB_IOT
//	#define MODBUS_TCP 1
//#else
//	#define MODBUS_TCP 0
//#endif /*MODBUS_4G_CAT1 | MODBUS_NB_IOT*/

//#if MQTT_NB_IOT|MQTT_4G_CAT1|MQTT_LORA
//	#define MQTT 1
//#else
//	#define MQTT 0
//#endif /*MQTT_NB_IOT|MQTT_4G_CAT1|MQTT_LORA*/


//端口参数配置，1不可省略（用于脚本检测识别）
#if RS485 == 1
#define RS485_BaudRate 9600
#define RS485_WordLength UART_WORDLENGTH_8B
#define RS485_StopBits UART_STOPBITS_2
#define RS485_Parity UART_PARITY_NONE
#endif /*RS485*/



/* Private typedef----------------------------------------------------------------------------*/

/* Private macro------------------------------------------------------------------------------*/

/* Private variables--------------------------------------------------------------------------*/

/* Private function prototypes----------------------------------------------------------------*/

/* Private functions--------------------------------------------------------------------------*/

#endif /* TOP_SCHEME_H_ */
